package com.xingxuecn.limit.dao;

import com.xingxuecn.limit.common.model.Page;
import com.xingxuecn.limit.common.model.User;

import java.sql.SQLException;
import java.util.List;

/**
 * @author 你的名字 at 2018/9/11 14:35
 */
public interface UserDao {
    List<User> findAll() throws SQLException;

    int add(User user) throws SQLException;

    int update(User user) throws SQLException;

    int delete(Integer id) throws SQLException;

    int count(User user) throws SQLException;

    List<User> search(User user, Integer... limit) throws SQLException;

    Page searchPage(User user, Integer page, Integer rows) throws SQLException;
}
